﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Web.Script.Services;

namespace MyTemplate
{
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [System.ComponentModel.ToolboxItem(false)]
    [System.Web.Script.Services.ScriptService]
    public class ArticleService : System.Web.Services.WebService
    {
        [WebMethod]
        [ScriptMethod(ResponseFormat = ResponseFormat.Json)]
        public string GetJSONData()
        {
            //Console.WriteLine("GetJSONData begin");
            //HttpResponse response = HttpContext.Current.Response;
            ArticleManager am = new ArticleManager();
            //response.Write(am.getArticlesJSON(""));
            return am.getArticlesJSON("");
        }


    }
}
